home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Source Code / C / Games / Xconq 7.0d16 / lib / monster.g < prev    next >
Encoding:
Text File  |  1993-12-20  |  3.9 KB  |  163 lines  |  [TEXT/MPS ]

  1. ;;; Reliving those old movies...
  2.  
  3. (game-module "monster"
  4.   (blurb "Type defns for Tokyo 1962")
  5. )
  6.  
  7. (set see-all true)
  8.  
  9. (unit-type monster (image-name "monster")
  10.   (point-value 100)
  11.   (help "breathes fire and stomps on buildings"))
  12. (unit-type |fire breath| (image-name "breath")
  13.   (help "burns things up"))
  14. (unit-type fire (image-name "fire")
  15.   (help "burns things up"))
  16. (unit-type mob (name "panic-stricken mob") (image-name "horde")
  17.   (help "helpless civilians"))
  18. (unit-type |fire department| (image-name "fireman")
  19.   (help "puts out fires"))
  20. (unit-type |national guard| (image-name "soldiers")
  21.   (help "does battle with the monster"))
  22. (unit-type building (image-name "city20")
  23.   (point-value 1)
  24.   (help "good for hiding, but crushed by monster"))
  25.  
  26. (define m monster)
  27. (define b |fire breath|)
  28. (define f fire)
  29. (define p mob)
  30. (define F |fire department|)
  31. (define g |national guard|)
  32. (define B building)
  33.  
  34. (material-type energy (help "required to make fires move"))
  35.  
  36. (terrain-type sea (color "sky blue") (char "."))
  37. (terrain-type beach (color "yellow") (image-name "desert") (char ","))
  38. (terrain-type street (color "light gray") (image-name "road") (char "+"))
  39. (terrain-type junkheap (color "sienna") (image-name "hills") (char "^"))
  40. (terrain-type fields (color "green") (image-name "plains") (char "="))
  41. (terrain-type trees (color "forest green") (image-name "forest") (char "%"))
  42.  
  43. (define movers (m b f p F g))
  44. (define water (sea))
  45. (define land (beach street junkheap fields trees))
  46.  
  47. (define fires (b f))
  48.  
  49. (add (m b f) possible-sides "monster")
  50. (add (p F g B) possible-sides "human")
  51.  
  52.  
  53. (table vanishes-on
  54.   (u* water true)
  55.   (monster water false)
  56.   ;; fire trucks and mobs can only go along the streets
  57.   ((p F) t* true)
  58.   ((p F) street false)
  59.   )
  60.  
  61. ;;; Fires sometimes die down on their own.
  62. (table attrition
  63.   (fires t* 3000)
  64.   (fires street 5000) ; not much fuel in the middle of the street
  65.   (fires junkheap 2000)  ; but junkheaps are good
  66. )
  67.  
  68. ;1 e m produce
  69. ;100 t* m productivity
  70. ;1 e m storage
  71. ;1 e b storage
  72. ;1 f b make
  73. ;100 t* f productivity
  74.  
  75. (add movers acp-per-turn (1 1 1 1 2 2))
  76.  
  77. (table mp-to-enter-terrain
  78.   (u* water 99)
  79.   (monster water 0)
  80.   ((p F) t* 99)
  81.   ((p F) street 0)
  82.   )
  83.  
  84. (table acp-to-create
  85.   (m b 1)
  86.   (b f 1)
  87.   )
  88.  
  89. ;1 e b to-move
  90.  
  91. (table unit-capacity-x
  92.   (B (p F g) 1)
  93.   (m b 2)
  94.   (b f 2)
  95. )
  96.  
  97. (add u* hp-max (100 5 5 1 2 5 6))
  98.  
  99. (table hit-chance
  100.   (m u* (50 50 50 50 100 80 100))
  101.   (b u* ( 0  0  0 40 40 40 90))
  102.   (f u* ( 0  0  0 40  0 40 90))
  103.   (p u* ( 0 10 10  0  0  0  0))
  104.   (F u* ( 0 90 90  0  0  0  0))
  105.   (g u* (80 40 40  0  0  0  0))
  106.   (B u* (10 20 20  0  0  0  0))
  107. )
  108.  
  109. (table damage
  110.   (u* u* 1)
  111.   (g m 4)
  112.   (F (b f) (2 5))
  113.   ((m b f) B (3 6 3))
  114. )
  115.  
  116. ;(add u* destroy-message
  117. ;  ("kills" "extinguishes" "extinguishes" "massacres" "wipes out" "wipes out" "flattens"))
  118.  
  119. ;[ 05 0 90 50 20 ] movers retreat
  120.  
  121. ;0 p control
  122. ;0 f control
  123.  
  124. ;50 [ p F g ] B protect
  125.  
  126.  
  127. (add m namer "monster-names")
  128.  
  129. (namer monster-names (random
  130.   "Godzilla" "Rodan" "Mothra" "Megalon" "Gajira" "Aspidra"
  131.   "Reptilicus" "Gamera"
  132.   ))
  133.  
  134. ;;; Random setup, for testing.
  135.  
  136. (add t* alt-percentile-min (  0  20  25  35  80  90 ))
  137. (add t* alt-percentile-max ( 20  25  35  80  90 100 ))
  138. (add t* wet-percentile-min 0)
  139. (add t* wet-percentile-max 100)
  140.  
  141. (set country-radius-min 5)
  142.  
  143. (add u* start-with (1 0 0 10 3 3 10))
  144.  
  145. (table favored-terrain
  146.   (u* sea 0)
  147.   )
  148.  
  149. (game-module (notes (
  150.   "Typically, one would set up a scenario with one or more monsters on"
  151.   "one side, and mobs, fire departments, and national guards on the"
  152.   "other.  Note"
  153.   "that the monster can easily defeat national guards one after another,"
  154.   "and that the most successful strategy for the "human" side is to"
  155.   "attack the monster with several units at once.  The monster can use"
  156.   "fires as a barricade to keep the national guards from getting close"
  157.   "enough to attack.  Destroying buildings is fun but not very useful."
  158.   ""
  159.   "Sandra Loosemore (sandra@cs.utah.edu) is the person to blame for this"
  160.   "piece of silliness (well, Stan aided and abetted)."
  161. )))
  162.  
  163.